﻿<%@ Page Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="AccionDeMarketingComunicacionEdit.aspx.cs"
    Inherits="CrmContacto.WebApp.App.AccionDeMarketingComunicacionEdit" %>

<%@ Import Namespace="Web.Framework.Translate" %>
<asp:Content ID="HeaderContent" ContentPlaceHolderID="HeadContent" runat="server">
    <script src="/Scripts/App/AccionDeMarketingEdit.js" type="text/javascript"></script>
    <link href="/Styles/App/AccionDeMarketing.css" rel="stylesheet" type="text/css" />
</asp:Content>
<asp:Content ID="BodyContent" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        <asp:Literal ID="lit1" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.TituloGenerico"]%>' />
        <asp:Label ID="lblEspecificacionDeMarketing" runat="server" Text="Label"></asp:Label>
        <img width="15px" height="15px" id="imgExpand" class="imgExpand" src="/Images/icon_blockexpanded.png"
            onclick="window.AppCommonObj.toggleVisibility(this.id, 'accionDeMarketingEditDiv');"
            alt="" />
        <span class="clear"></span>
    </h2>
    <div id="tabsEdit" class="marketingTabs">
        <ul>
            <li><a href="#accionDeMarketingEditDiv">
                <asp:Literal ID="Literal6" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.Tab.Edicion"]%>' /></a></li>
            <li><a href="#accionDeMarketingInversion">
                <asp:Literal ID="Literal8" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.Tab.Inversion"]%>' /></a></li>
        </ul>
        <div class="editionContainerFilter" id="accionDeMarketingEditDiv">
            <p>
                <span class="title2">
                    <asp:Literal ID="Literal1" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.PlanDeMarketing"]%>' />:</span>
                <asp:TextBox ID="txtNombrePlanDeMarketing" runat="server" CssClass="inputs readonly"
                    ClientIDMode="Static"></asp:TextBox>
                <asp:LinkButton ID="lnkIrAPlan" CssClass="lnkVerClass" runat="server">
                    <asp:Literal ID="Literal13" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.Command.Ver"]%>' /></asp:LinkButton>
            </p>
            <div class="clear">
            </div>
            <p>
                <span class="title2">
                    <asp:Literal ID="Literal10" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Nombre"]%>' />:</span>
                <asp:TextBox ID="txtNombre" runat="server" CssClass="inputs" ClientIDMode="Static"
                    title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Nombre"] %>'></asp:TextBox>
            </p>
            <div class="clear">
            </div>
            <p>
                <span class="title2">
                    <asp:Literal ID="Literal4" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Descripcion"]%>' />:</span>
                <asp:TextBox ID="txtDescripcion" TextMode="MultiLine" runat="server" CssClass="inputs inputMultiline"
                    ClientIDMode="Static" title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Descripcion"] %>'></asp:TextBox>
            </p>
            <div class="clear">
            </div>
            <p>
                <span class="title2">
                    <asp:Literal ID="Literal23" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["PlanDeMarketing.Responsable"]%>' />:</span>
                <asp:TextBox ID="txtResposable" runat="server" CssClass="inputs inputlong" ClientIDMode="Static"
                    title='<%$ Code:  LocalizationProvider.Instance["PlanDeMarketing.Responsable"] %>'></asp:TextBox>
            </p>
            <div class="clear">
            </div>
            <p>
                <span class="title2">
                    <asp:Literal ID="Literal5" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Codigo"]%>' />:</span>
                <asp:TextBox ID="txtCodigo" runat="server" CssClass="inputs" ClientIDMode="Static"
                    title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Codigo"] %>'></asp:TextBox>
            </p>
            <div class="clear">
            </div>
            <div class="divp">
                <span class="title2">
                    <asp:Literal ID="litFechaEventoDesde" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.FechaLanzamiento"]%>' />:</span>
                <asp:TextBox ID="txtFechaDesde" runat="server" CssClass="inputs" ClientIDMode="Static"></asp:TextBox>
            </div>
            <%--<div class="divp" runat="server" id="divFechaEventoHasta">
                <span class="title2 secondColumn">
                    <asp:Literal ID="Literal7" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.FechaEventoHasta"]%>' />:</span>
                <asp:TextBox ID="txtFechaHasta" runat="server" CssClass="inputs" ClientIDMode="Static"></asp:TextBox>
                <div class="clear">
                </div>
            </div>--%>
            <div class="clear">
            </div>
            <div>
                <p>
                    <span class="title2">
                        <asp:Literal ID="Literal2" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Discriminador"]%>' />:</span>
                    <asp:Label ID="lblTipoAccionDeMarketing" runat="server" Text=""></asp:Label>
                </p>
            </div>
            <div class="clear">
            </div>
            <div class="divp">
                <span class="title2">
                    <asp:Literal ID="Literal9" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["PlanDeMarketing.Estado"]%>' />:</span>
                <%-- <asp:DropDownList ID="cboEstado" runat="server" CssClass="cbo readonly" ClientIDMode="Static"
                        Enabled="false">
                    </asp:DropDownList>--%>
                <asp:Label ID="lblEstado" runat="server" Text=""></asp:Label>
            </div>
            <div class="clear">
            </div>
        </div>
        <div class="editionContainerFilter" id="accionDeMarketingInversion">
            <div class="divDatosLeft">
                <div>
                    <p>
                        <span class="title2">
                            <asp:Literal ID="Literal11" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Inversion"]%>' />:</span>
                        <asp:TextBox ID="txtInversion" runat="server" CssClass="inputs numberRight" ClientIDMode="Static"
                            title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Inversion"] %>'></asp:TextBox>
                    </p>
                    <div class="clear">
                    </div>
                    <p>
                        <span class="title2">
                            <asp:Literal ID="Literal12" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.ROIDinero"]%>' />:</span>
                        <asp:TextBox ID="txtROIDinero" runat="server" CssClass="inputs numberRight" ClientIDMode="Static"
                            title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.ROIDinero"] %>'></asp:TextBox>
                    </p>
                    <div class="clear">
                    </div>
                    <p>
                        <span class="title2">
                            <asp:Literal ID="Literal14" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.ROIPorcentaje"]%>' />:</span>
                        <asp:TextBox ID="txtROIPorcentaje" runat="server" CssClass="inputs numberRight" ClientIDMode="Static"
                            title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.ROIPorcentaje"] %>'></asp:TextBox>
                    </p>
                    <div class="clear">
                    </div>
                    <p>
                        <span class="title2">
                            <asp:Literal ID="Literal15" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.EficaciaEsperada"]%>' />:</span>
                        <asp:TextBox ID="txtEficaciaEsperada" runat="server" CssClass="inputs numberRight"
                            ClientIDMode="Static" title='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.EficaciaEsperada"] %>'></asp:TextBox>
                    </p>
                    <div class="clear">
                    </div>
                </div>
            </div>
            <div class="clear">
            </div>
        </div>
    </div>
    <div class="commandBarDiv">
        <%--<asp:LinkButton ID="lnkGuardar" runat="server" CssClass="guardar" OnClick="lnkGuardar_Click" ClientIDMode="Static"></asp:LinkButton>--%>
        <asp:LinkButton ID="lnkGuardar" runat="server" CssClass="guardar">
            <asp:Literal ID="Literal26" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.Command.Guardar"]%>' /></asp:LinkButton>
        <div class="clear">
        </div>
        <br />
        <asp:Panel ID="pnlTabs" runat="server">
            <h2>
                <asp:Image Width="15px" Height="15px" ID="Image1" CssClass="imgExpand" ImageUrl="/Images/icon_blockcollapsed.png"
                    runat="server" ClientIDMode="Static" alt="" />
                <asp:Literal ID="Literal3" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.AccionDeMarketing.TituloTabs"]%>' />
                <asp:Label ID="Label1" runat="server" Text="" CssClass="lblSearchResult"></asp:Label>
            </h2>
            <div id="tabs" class="customerTabs">
                <asp:Literal ID="litTabs" runat="server"></asp:Literal>
                <%--<ul>
            <li ><a href="#pnlListasDeDistribucion">
                <asp:Literal ID="Literal2" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.Tab.Listas"]%>' /></a></li>
            <li ><a href="#pnlResults">
                <asp:Literal ID="Literal8" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.Tab.Resultados"]%>' /></a></li>
            <li><a href="#pnlAmbito">
                <asp:Literal ID="Literal11" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.Tab.Ambitos"]%>' /></a></li>
            <li ><a href="#pnlAccionesDeMarketing">
                <asp:Literal ID="Literal12" runat="server" Text='<%$ Code:  LocalizationProvider.Instance["Bo.AccionDeMarketing.Tab.Comunicaciones"]%>' /></a></li>
        </ul>--%>
                <asp:Panel ID="pnlListasDeDistribucion" CssClass="editionContainerForGrid" runat="server"
                    ClientIDMode="Static">
                    <div class="clear">
                    </div>
                    <div style="float: right;">
                        <asp:LinkButton ID="lnkExportarAExcel" CssClass="promolnkExportarAExcel" ClientIDMode="Static"
                            OnClick="lnkExportarAExcelListaDeDistribucion_Click" runat="server">
                            <img style="text-decoration: none; border: 0px; margin-right: 4px" src="../Images/excel.png"
                                alt="" /><asp:Literal ID="Literal24" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.SearchContacto.CmdExportarExcel"]%>' /></asp:LinkButton>
                    </div>
                    <div class="clear">
                    </div>
                    <asp:GridView ID="GridListasDistribucion" runat="server" CellPadding="4" ForeColor="#333333"
                        GridLines="None" AutoGenerateColumns="False" DataKeyNames="Id" Width="100%" AllowPaging="False"
                        PageSize="15" OnRowCommand="GridListasDistribucion_RowCommand" OnRowDataBound="GridListasDistribucion_RowDataBound">
                        <AlternatingRowStyle BackColor="White" />
                        <Columns>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEditar" runat="server" ImageUrl="~/Images/editar.png" CommandName="editar"
                                        CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEliminar" runat="server" ImageUrl="~/Images/eliminar.png"
                                        CommandName="eliminar" CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Id" HeaderText="Id" Visible="false">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Nombre" HeaderText='<%$ Code:  LocalizationProvider.Instance["MaestroBase.Nombre"] %>'
                                SortExpression="Nombre">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                        </Columns>
                        <EditRowStyle BackColor="#2461BF" />
                        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#4b6c9e" Font-Bold="True" ForeColor="White" HorizontalAlign="Left"
                            CssClass="gridSortingHeader" />
                        <PagerStyle BackColor="#4b6c9e" ForeColor="White" HorizontalAlign="Center" />
                        <RowStyle BackColor="#EFF3FB" />
                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#F5F7FB" />
                        <SortedAscendingHeaderStyle BackColor="#6D95E1" CssClass="gridSortingHeader" />
                        <SortedDescendingCellStyle BackColor="#E9EBEF" />
                        <SortedDescendingHeaderStyle BackColor="#4870BE" CssClass="gridSortingHeader" />
                    </asp:GridView>
                </asp:Panel>
                <asp:Panel ID="pnlResults" CssClass="editionContainerForGrid" runat="server" ClientIDMode="Static">
                <div style="float: right;">
                        <asp:LinkButton ID="LinkButton1" CssClass="promolnkExportarAExcel" ClientIDMode="Static"
                            OnClick="lnkExportarAExcelResultados_Click" runat="server">
                            <img style="text-decoration: none; border: 0px; margin-right: 4px" src="../Images/excel.png"
                                alt="" /><asp:Literal ID="Literal7" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.SearchContacto.CmdExportarExcel"]%>' /></asp:LinkButton>
                    </div>
                    <div class="clear">
                    </div>
                    <asp:GridView ID="GridResultados" runat="server" CellPadding="4" ForeColor="#333333"
                        GridLines="None" AutoGenerateColumns="False" DataKeyNames="Id" Width="100%" AllowPaging="False"
                        OnRowDataBound="GridResultados_RowDataBound" OnRowCommand="GridResultados_RowCommand">
                        <AlternatingRowStyle BackColor="White" />
                        <Columns>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEliminar" runat="server" ImageUrl="~/Images/eliminar.png"
                                        CommandName="eliminar" CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Email" HeaderText='<%$ Code:  LocalizationProvider.Instance["Contacto.Email"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="EmailTipoRebote" HeaderText='<%$ Code:  LocalizationProvider.Instance["ResultadosEmailMarketing.EmailTipoRebote"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:CheckBoxField DataField="EmailLlego" HeaderText='<%$ Code:  LocalizationProvider.Instance["ResultadosEmailMarketing.EmailLlego"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:CheckBoxField>
                            <asp:CheckBoxField DataField="EmailAbierto" HeaderText='<%$ Code:  LocalizationProvider.Instance["ResultadosEmailMarketing.EmailAbierto"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:CheckBoxField>
                            <asp:CheckBoxField DataField="AccionEjecutada" HeaderText='<%$ Code:  LocalizationProvider.Instance["ResultadosEmailMarketing.AccionEjecutada"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:CheckBoxField>
                            <asp:BoundField DataField="EmailFechaApertura" HeaderText='<%$ Code:  LocalizationProvider.Instance["ResultadosEmailMarketing.EmailFechaApertura"] %>'
                                DataFormatString="{0:dd/MM/yyyy}">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="FechaAltaRegistro" HeaderText='<%$ Code:  LocalizationProvider.Instance["ResultadosEmailMarketing.FechaAltaRegistro"] %>'
                                DataFormatString="{0:dd/MM/yyyy}">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                        </Columns>
                        <EditRowStyle BackColor="#2461BF" />
                        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#4b6c9e" Font-Bold="True" ForeColor="White" HorizontalAlign="Left" />
                        <PagerStyle BackColor="#4b6c9e" ForeColor="White" HorizontalAlign="Center" />
                        <RowStyle BackColor="#EFF3FB" />
                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#F5F7FB" />
                        <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                        <SortedDescendingCellStyle BackColor="#E9EBEF" />
                        <SortedDescendingHeaderStyle BackColor="#4870BE" />
                    </asp:GridView>
                </asp:Panel>
                <asp:Panel ID="pnlAmbito" CssClass="editionContainerForGrid" runat="server" ClientIDMode="Static">
                    <div class="clear">
                    </div>
                     <div style="float: right;">
                        <asp:LinkButton ID="LinkButton2" CssClass="promolnkExportarAExcel" ClientIDMode="Static"
                            OnClick="lnkExportarAExcelAmbitos_Click" runat="server">
                            <img style="text-decoration: none; border: 0px; margin-right: 4px" src="../Images/excel.png"
                                alt="" /><asp:Literal ID="Literal16" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.SearchContacto.CmdExportarExcel"]%>' /></asp:LinkButton>
                    </div>
                    <div class="clear">
                    </div>
                    <asp:GridView ID="GridAmbito" runat="server" CellPadding="4" ForeColor="#333333"
                        GridLines="None" AutoGenerateColumns="False" DataKeyNames="Id" Width="100%" AllowPaging="False"
                        OnRowDataBound="GridAmbito_RowDataBound" OnRowCommand="GridAmbito_RowCommand">
                        <AlternatingRowStyle BackColor="White" />
                        <Columns>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEditar" runat="server" ImageUrl="~/Images/editar.png" CommandName="editar"
                                        CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEliminar" runat="server" ImageUrl="~/Images/eliminar.png"
                                        CommandName="eliminar" CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Id" HeaderText="Id" Visible="false">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Nombre" HeaderText='<%$ Code:  LocalizationProvider.Instance["MaestroBase.Nombre"] %>'
                                SortExpression="Nombre">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                        </Columns>
                        <EditRowStyle BackColor="#2461BF" />
                        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#4b6c9e" Font-Bold="True" ForeColor="White" HorizontalAlign="Left" />
                        <PagerStyle BackColor="#4b6c9e" ForeColor="White" HorizontalAlign="Center" />
                        <RowStyle BackColor="#EFF3FB" />
                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#F5F7FB" />
                        <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                        <SortedDescendingCellStyle BackColor="#E9EBEF" />
                        <SortedDescendingHeaderStyle BackColor="#4870BE" />
                    </asp:GridView>
                </asp:Panel>
                <asp:Panel ID="pnlAccionesDeMarketing" CssClass="editionContainerForGrid" runat="server"
                    ClientIDMode="Static">
                    <div class="clear">
                    </div>
                    <div style="float: right;">
                        <asp:LinkButton ID="LinkButton3" CssClass="promolnkExportarAExcel" ClientIDMode="Static"
                            OnClick="lnkExportarAExcelAccionesDeMkt_Click" runat="server">
                            <img style="text-decoration: none; border: 0px; margin-right: 4px" src="../Images/excel.png"
                                alt="" /><asp:Literal ID="Literal17" runat="server" Text='<%$ Code: LocalizationProvider.Instance["Bo.SearchContacto.CmdExportarExcel"]%>' /></asp:LinkButton>
                    </div>
                    <div class="clear">
                    </div>
                    <asp:GridView ID="GridAccionesDeMarketing" runat="server" CellPadding="4" ForeColor="#333333"
                        GridLines="None" AutoGenerateColumns="False" DataKeyNames="Id" Width="100%" AllowPaging="False"
                        PageSize="15" OnRowCommand="GridAccionesDeMarketing_RowCommand" OnRowDataBound="GridAccionesDeMarketing_RowDataBound">
                        <AlternatingRowStyle BackColor="White" />
                        <Columns>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEditar" runat="server" ImageUrl="~/Images/editar.png" CommandName="editar"
                                        CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="">
                                <HeaderStyle HorizontalAlign="Left" Width="30px" />
                                <ItemStyle HorizontalAlign="Center" />
                                <ItemTemplate>
                                    <asp:ImageButton ID="btnEliminar" runat="server" ImageUrl="~/Images/eliminar.png"
                                        CommandName="eliminar" CommandArgument="<%# ((GridViewRow) Container).RowIndex %>" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Nombre" HeaderText='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Nombre"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="CodigoParaPDV" HeaderText='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Codigo"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="FechaDesde" HeaderText='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.FechaEventoDesde"] %>'
                                DataFormatString="{0:dd/MM/yyyy}">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="FechaHasta" HeaderText='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.FechaEventoHasta"] %>'
                                DataFormatString="{0:dd/MM/yyyy}">
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Discriminador" HeaderText='<%$ Code:  LocalizationProvider.Instance["AccionDeMarketing.Discriminador"] %>'>
                                <HeaderStyle HorizontalAlign="Left" />
                            </asp:BoundField>
                        </Columns>
                        <EditRowStyle BackColor="#2461BF" />
                        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#4b6c9e" Font-Bold="True" ForeColor="White" HorizontalAlign="Left"
                            CssClass="gridSortingHeader" />
                        <PagerStyle BackColor="#4b6c9e" ForeColor="White" HorizontalAlign="Center" />
                        <RowStyle BackColor="#EFF3FB" />
                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#F5F7FB" />
                        <SortedAscendingHeaderStyle BackColor="#6D95E1" CssClass="gridSortingHeader" />
                        <SortedDescendingCellStyle BackColor="#E9EBEF" />
                        <SortedDescendingHeaderStyle BackColor="#4870BE" CssClass="gridSortingHeader" />
                    </asp:GridView>
                </asp:Panel>
            </div>
        </asp:Panel>
        <br />
    </div>
    <script type='text/javascript'>

        $(document).ready(function () {

            if (!window.AppCommonObj) {
                window.AppCommonObj = new AppCommon();
            }

            if (!window.CrmCommonObj) {
                window.CrmCommonObj = new CrmCommon();
            }

            $('#txtFechaDesde').datepick({ dateFormat: 'dd/mm/yyyy' });
            $('#txtFechaHasta').datepick({ dateFormat: 'dd/mm/yyyy' });

            var DiscriminadorMarketing = {
                Publicidad: 1,
                Promocion: 2,
                Comunicacion: 3
            };

            if (!window.AccionDeMarketingEditObj) {
                window.AccionDeMarketingEditObj = new AccionDeMarketingEdit(DiscriminadorMarketing.Comunicacion);
            }

            $("#tabs").tabs();
            $("#tabsEdit").tabs();

            $('input[title]').inputHints();

            document.DirtyCheck = new DirtyCheck();
            document.DirtyCheck.loadControlState();

            AppCommonObj.ConfirmMovePage();

        });

    </script>
</asp:Content>
